
<template>
<no v-if="store.state.user.uname!=''"></no>
<ces v-if="store.state.user.uname==''&&store.state.gologin"></ces>
<div style="margin-top: 3.75rem;">
	<router-view></router-view>
</div>
	<div style="position: fixed;
  bottom: 0;
  left: 0;
  right: 0;">
		
	</div>
</template>

<script setup>
import {ref, reactive,onMounted,computed} from"vue"
import {$get,$postx,$postj,$postf} from './ajax/index.js'
import router from"./router/index.js"
import ces from "./components/ces.vue"
import no from "./components/no.vue"
import store from"./store/index.js"
onMounted(()=>{
	
	let a=window.localStorage.getItem("token")
	if(a!=undefined&&a!=""){
		$get("/user/info").then(function(resd){
			console.log(resd.data)
			const d= resd.data[1].data[1]
			store.state.user=d
			const c=d.perm[1].vip
			console.log(c)
			if(c=="cus"){
				router.push("/home/com/recom")
			}else
			router.push("/"+c)
		})
		}else{
			router.push("/home")
		}
})


</script>


<style>

</style>
